<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head profile="http://selenium-ide.openqa.org/profiles/test-case">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="selenium.base" href="http://beta.mamsy.ru/" />
<title>beta_full_reviews_test</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">beta_full_reviews_test</td></tr>
</thead><tbody>
<tr>
	<td>setSpeed</td>
	<td>0</td>
	<td></td>
</tr>
<tr>
	<td>open</td>
	<td>/</td>
	<td></td>
</tr>
<!--Выбор рандомного лоигна покупателя-->
<tr>
	<td>storeEval</td>
	<td>[546223,546174,546154,546052,545880,545852,545832,545802,545800,545756,545598,545580,545462,545248,545160,545119,545117,545072,545026,544967,544965,544865,544730,544466,544404,544337,544274,544195,544119,544045,543958,543863,543762,543661,543600,543568,543463,543445,543415,543374,543367,543332,543252,543188,543081,542786,542731,542698,542601,542449,542298,542070,542058,542046,541958,541887,541867,541832,541816,541728,541641,541634,541264,541064,540997,540987,540842,540809,540495,540493,540338,540285,540270,540244,540206,540057,540037,539956,539926,539741,539666,539582,539526,539462,539240,539235,539231,539117,539093,538934,538853,538694,538607,538507,538475,538432,538361,538278,538245,538174,538098,537907,537836,537822,537810,537590,537577,537571,537540,537468,537398,537359,537226,537204,537196,537068,537018,537000,536969,536918,536872,536744,536688,536678,536662,536626,536603,536468,536423,536384,536373,536333,536308,536307,536257,536179,536032,536024,535994,535853,535822,535809,535776,535575,535571,535526,535416,535324,535180,535140,535037,534979,534935,534926,534885,534800,534748,534622,534598,534566,534558,534478,534408,534351,534317,534270,534256,534211,534210,534151,534142,534042,533848,533812,533758,533713,533670,533643,533617,533393,533356,533234,533197,532879,532798,532755,532752,532727,532672,532650,532534,532499,532462,532461,532431,532365,532215,532183,532128,532122,532107,532051,531910,531899,531451,531429,531399,531395,531208,531099,530952,530905,530898,530760,530704,530590,530583,530419,530394,530370,530252,530207,530159,530099,530007,529863,529794,529791,529666,529635,529611,529481,529460,529401,529361,529353,529326,529194,529186,529161,529109,529093,529051,528901,528809,528776,528734,528668,528622,528523,528412,528321,528292,528268,528260,528113,527990,527882,527867,527822,527676,527500,527445,527389,527171,527119,527050,526949,526906,526808,526804,526799,526783,526727,526724,526693,526670,526618,526526,526430,526405,526306,526265,526128,526120,526028,525994,525978,525837,525796,525788,525780,525660,525590,525531,525517,525511,525316,525310,525287,525184,525171,524814,524788,524768,524747,524600,524547,524515,524458,524284,524221,523926,523702,523651,523604,523584,523433,523323,522925,522892,522766,522634,522219,522209,522154,521974,521938,521931,521886,521730,521713,521699,521675,521492,521249,521103,520940,520743,520545,520464,520459,520438,520382,520288,520206,520188,520160,520082,519790,519569,519263,519225,519210,519122,519008,518987,518940,518917,518900,518894,518785,518750,518728,518662,518628,518625,518606,518528,518338,518334,518331,518302,518271,518240,518200,518185,518158,518144,518089,518002,517926,517910,517868,517867,517850,517642,517620,517519,517510,517500,517472,517426,517408,517355,517343,517307,517298,517275,517266,517090,517024,517001,516958,516927,516877,516743,516666,516587,516530,516482,516481,516382,516369,516254,516165,516156,516126,516088,516028,515970,515934,515885,515853,515835,515818,515783,515742,515684,515668,515511,515440,515410,515408,515277,515232,515219,515182,515113,515066,515004,514983,514959,514827,514743,514660,514483,514463,514277,514239,514172,514164,514154,514075,513988,513881,513648,513552,513486,513207,513160,513157,513092,513075,513029,512997,512955,512800,512790,512775,512738,512677,512647,512615,512610,512578,512555,512520,512517,512490,512394,512293,512247,512235,512128,512101,512084,512023,511999,511988,511944,511897,511873,511740,511709,511691,511633,511603,511597,511523,511414,511403,511382,511347,511338,511305,511290,511288,511282,511213,511186,511149,511137,511101,511089,511086,511024,511006,510931,510917,510861,510851,510837,510801,510739,510568,510469,510440,510387,510329,510326,510315,510287,510199,510195,510194,510058,510021,509930,509860,509855,509760,509679,509649,509638,509621,509572,509501,509394,509283,509189,509087,508995,508978,508942,508842,508801,508712,508676,508666,508612,508494,508451,508374,508346,508322,508278,508272,508255,508249,508128,508069,507993,507927,507893,507768,507645,507624,507540,507376,507314,507209,507130,507027,506973,506925,506903,506869,506788,506772,506719,506548,506528,506515,506415,506378,506273,505971,505939,505891,505795,505686,505564,505530,505444,505298,505200,505157,504985,504942,504929,504813,504678,504625,504569,504450,504416,504360,504350,504313,504300,504278,504263,503950,503918,503831,503766,503668,503501,503491,503453,503431,503384,503328,503282,503243,503219,503202,503134,503101,503057,502739,502510,502470,502361,502337,502321,502292,502274,502263,502208,502180,502175,502157,502110,502105,502091,502015,501990,501968,501953,501936,501880,501818,501808,501791,501685,501659,501650,501602,501596,501550,501423,501422,501374,501360,501259,501221,501212,501065,501058,501037,500859,500830,500817,500812,500809,500602,500480,500468,500368,500253,500202,500128,500098,500088,500045,499898,499893,499755,499643,499575,499553,499501,499468,499372,499343,499334,499309,499248,499166,499126,499122,499074,499007,498963,498942,498722,498700,498642,498617,498608,498510,498452,498428,498402,498396,498376,498345,498338,498275,498267,498263,498149,498048,498036,498000,497939,497917,497804,497788,497767,497648,497635,497631,497623,497572,497522,497483,497460,497428,497403,497386,497359,497343,497335,497330,497318,497273,497269,497246,497234,497202,497127,497116,497102,497087,496966,496922,496858,496853,496845,496833,496761,496753,496702,496678,496629,496601,496514,496458,496452,496447,496415,496389,496362,496327,496326,496301,496298,496278,496236,496100,496054,496050,496025,496007,495974,495960,495934,495873,495857,495768,495721,495719,495716,495709,495676,495670,495664,495648,495645,495639,495609,495579,495561,495533,495452,495365,495352,495341,495338,495248,495098,495096,495074,495068,495034,494914,494879,494836,494832,494821,494808,494725,494721,494704,494686,494622,494619,494572,494553,494533,494474,494408,494392,494368,494306,494282,494259,494181,494125,494090,494025,493997,493968,493941,493915,493880,493850,493799,493764,493751,493710,493683,493667,493599,493455,493352,493347,493300,493296,493278,493277,493235,493219,493144,493102,493089,493027,493015,492923,492912,492887,492874,492872,492823,492700,492697,492678,492602,492414,492160,492110,492037,492008,491984,491941,491865,491849,491760,491714,491708,491657,491575,491525,491370,491335,491237,491227,491120,491052,491045,491035,491030,491016,490939,490906,490689,490571,490569,490511,490483,490452,490388,490368,490328,490305,490229,490164,490013,489959,489913,489889,489864,489843,489841,489839,489794,489698,489653,489621,489547,489444,489403,489315,489301,489088,489085,489035,489030,488962,488843,488832,488805,488599,488590,488584,488554,488533,488491,488468,488425,488418,488361,488273,488264,488254,488241,488205,488202,488198,488195,488129,488060,487968,487949,487942,487884,487865,487800,487784,487751,487651,487603,487583,487556,487554,487512,487505,487497,487395,487382,487335,487310,487299,487249,487199,487098]</td>
	<td>array_buyers_id</td>
</tr>
<tr>
	<td>echo</td>
	<td>${array_buyers_id}</td>
	<td></td>
</tr>
<tr>
	<td>storeEval</td>
	<td>storedVars['array_buyers_id'].length</td>
	<td>array_buyers_id_quantity</td>
</tr>
<tr>
	<td>echo</td>
	<td>${array_buyers_id}</td>
	<td></td>
</tr>
<tr>
	<td>storeEval</td>
	<td>Math.floor(Math.random() * (0-${array_buyers_id_quantity}+1)+${array_buyers_id_quantity})</td>
	<td>array_random_index</td>
</tr>
<tr>
	<td>echo</td>
	<td>${array_random_index}</td>
	<td></td>
</tr>
<tr>
	<td>storeEval</td>
	<td>storedVars['array_buyers_id'][storedVars['array_random_index']]</td>
	<td>array_random_id</td>
</tr>
<tr>
	<td>echo</td>
	<td>${array_random_id}</td>
	<td></td>
</tr>
<tr>
	<td>storeEval</td>
	<td>${array_random_id}+'@mailforspam.com'</td>
	<td>random_login</td>
</tr>
<tr>
	<td>echo</td>
	<td>${random_login}</td>
	<td></td>
</tr>
<tr>
	<td>storeEval</td>
	<td>if (selenium.isElementPresent(&quot;id=input-login_mail&quot;)==true){nextMove=&quot;login&quot;} else {nextMove=&quot;exit&quot;}</td>
	<td>loginPage</td>
</tr>
<tr>
	<td>gotolabel</td>
	<td>${loginPage}</td>
	<td></td>
</tr>
<tr>
	<td>label</td>
	<td>exit</td>
	<td></td>
</tr>
<tr>
	<td>clickAndWait</td>
	<td>id=logout</td>
	<td></td>
</tr>
<tr>
	<td>label</td>
	<td>login</td>
	<td></td>
</tr>
<tr>
	<td>type</td>
	<td>id=input-login_mail</td>
	<td>39@mailforspam.com</td>
</tr>
<tr>
	<td>click</td>
	<td>css=input.button__button</td>
	<td></td>
</tr>
<tr>
	<td>waitForElementPresent</td>
	<td>id=loginMessages</td>
	<td></td>
</tr>
<tr>
	<td>click</td>
	<td>css=#login-pass_view &gt; label.content__form__text__bg</td>
	<td></td>
</tr>
<tr>
	<td>type</td>
	<td>id=input-login_pass</td>
	<td>111111</td>
</tr>
<tr>
	<td>click</td>
	<td>css=input.button__button</td>
	<td></td>
</tr>
<tr>
	<td>storeEval</td>
	<td>if (selenium.isTextPresent('Notice')==false &amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('Error')==false &amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('Exception')==false&nbsp;&nbsp;&amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('vps_core')==false) {} else {alert('Error!')}</td>
	<td></td>
</tr>
<tr>
	<td>open</td>
	<td>http://beta.mamsy.ru/</td>
	<td></td>
</tr>
<tr>
	<td>clickAndWait</td>
	<td>link=О Мамси</td>
	<td></td>
</tr>
<tr>
	<td>clickAndWait</td>
	<td>link=Отзывы</td>
	<td></td>
</tr>
<tr>
	<td>waitForElementPresent</td>
	<td>id=reviewsText</td>
	<td></td>
</tr>
<tr>
	<td>type</td>
	<td>id=reviewsText</td>
	<td>тест_вопроса_тест_вопроса_тест_вопроса_тест_вопроса_тест_вопроса_тест_вопроса_тест_вопроса_тест_вопроса_тест_вопроса_тест_вопроса_тест_вопроса_тест_вопроса_</td>
</tr>
<tr>
	<td>click</td>
	<td>//input[@value='Отправить']</td>
	<td></td>
</tr>
<tr>
	<td>waitForElementPresent</td>
	<td>css=p.error</td>
	<td></td>
</tr>
<tr>
	<td>waitForElementPresent</td>
	<td>id=reviews_type_review</td>
	<td></td>
</tr>
<tr>
	<td>click</td>
	<td>id=reviews_type_review</td>
	<td></td>
</tr>
<tr>
	<td>storeEval</td>
	<td>if (selenium.isTextPresent('Notice')==false &amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('Error')==false &amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('Exception')==false&nbsp;&nbsp;&amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('vps_core')==false) {} else {alert('Error!')}</td>
	<td></td>
</tr>
<tr>
	<td>type</td>
	<td>id=reviewsText</td>
	<td>Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_Тест_отзыва_</td>
</tr>
<tr>
	<td>clickAndWait</td>
	<td>//input[@value='Отправить']</td>
	<td></td>
</tr>
<tr>
	<td>waitForElementPresent</td>
	<td>css=p.error</td>
	<td></td>
</tr>
<tr>
	<td>waitForPageToLoad</td>
	<td></td>
	<td></td>
</tr>
<tr>
	<td>click</td>
	<td>id=reviews_type_review</td>
	<td></td>
</tr>
<tr>
	<td>type</td>
	<td>id=reviewsText</td>
	<td>повторный тест отзыва</td>
</tr>
<tr>
	<td>clickAndWait</td>
	<td>//input[@value='Отправить']</td>
	<td></td>
</tr>
<tr>
	<td>clickAndWait</td>
	<td>css=img[alt=&quot;удалить&quot;]</td>
	<td></td>
</tr>
<!--добавляем комментарий, -->
<!--для удаления через админкку-->
<tr>
	<td>open</td>
	<td>http://beta.mamsy.ru/call/reviews</td>
	<td></td>
</tr>
<tr>
	<td>waitForElementPresent</td>
	<td>link=Менеджмент</td>
	<td></td>
</tr>
<tr>
	<td>storeText</td>
	<td>linkToReview</td>
	<td>p</td>
</tr>
<tr>
	<td>echo</td>
	<td>${p}</td>
	<td></td>
</tr>
<tr>
	<td>storeEval</td>
	<td>if (selenium.isTextPresent('Notice')==false &amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('Error')==false &amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('Exception')==false&nbsp;&nbsp;&amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('vps_core')==false) {} else {alert('Error!')}</td>
	<td></td>
</tr>
<tr>
	<td>open</td>
	<td>/call/reviews/review-change/reviewsId/${p}</td>
	<td></td>
</tr>
<tr>
	<td>waitForElementPresent</td>
	<td>id=answer</td>
	<td></td>
</tr>
<!--Удалить отзыв-->
<tr>
	<td>chooseOkOnNextConfirmation</td>
	<td></td>
	<td></td>
</tr>
<tr>
	<td>click</td>
	<td>id=deleteReview</td>
	<td></td>
</tr>
<tr>
	<td>waitForElementPresent</td>
	<td>link=Менеджмент</td>
	<td></td>
</tr>
<!--Добавляем ответ-->
<tr>
	<td>storeText</td>
	<td>linkToReview</td>
	<td>p</td>
</tr>
<tr>
	<td>echo</td>
	<td>${p}</td>
	<td></td>
</tr>
<tr>
	<td>open</td>
	<td>/call/reviews/review-change/reviewsId/${p}</td>
	<td></td>
</tr>
<tr>
	<td>waitForElementPresent</td>
	<td>id=answer</td>
	<td></td>
</tr>
<tr>
	<td>type</td>
	<td>id=answer</td>
	<td>Ответ_на_отзыв_Ответ_на_отзыв</td>
</tr>
<tr>
	<td>clickAndWait</td>
	<td>css=button.kd-button.kd-button-green</td>
	<td>изменить</td>
</tr>
<tr>
	<td>storeEval</td>
	<td>if (selenium.isTextPresent('Notice')==false &amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('Error')==false &amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('Exception')==false&nbsp;&nbsp;&amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('vps_core')==false) {} else {alert('Error!')}</td>
	<td></td>
</tr>
<!--Проверяем на сайте-->
<tr>
	<td>open</td>
	<td>/info/review/${p}</td>
	<td></td>
</tr>
<tr>
	<td>waitForElementPresent</td>
	<td>id=logo</td>
	<td></td>
</tr>
<tr>
	<td>assertTextPresent</td>
	<td>Ответ_на_отзыв_Ответ_на_отзыв </td>
	<td></td>
</tr>
<tr>
	<td>storeEval</td>
	<td>if (selenium.isTextPresent('Notice')==false &amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('Error')==false &amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('Exception')==false&nbsp;&nbsp;&amp;&amp;&nbsp;&nbsp;selenium.isTextPresent('vps_core')==false) {} else {alert('Error!')}</td>
	<td></td>
</tr>
